Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Killed RAG feature #727

Merged
merged 1 commit into from
Nov 21, 2024
Merged

fix: Killed RAG feature #727

merged 1 commit into from
Nov 21, 2024

Conversation

rflihxyz
Copy link
Contributor

@rflihxyz rflihxyz commented Nov 21, 2024

  • Removed RAG feature from Panora
  • AI Agents for Logistics & Ecommerce will be served from an isolated, closed-source service

Summary by CodeRabbit

  • New Features

    • Introduced a new Dockerfile for the web application to streamline the build process using Node.js and PNPM.
    • Updated the configuration for output file tracing in the Next.js application.
  • Bug Fixes

    • Removed the RAG settings functionality from the Dashboard configuration, simplifying the user interface.
  • Chores

    • Deleted multiple components and services related to RAG, including RAG settings, item management, and embedding services, to enhance application performance and maintainability.

Copy link

changeset-bot bot commented Nov 21, 2024

⚠️ No Changeset found

Latest commit: 22d7418

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link
Contributor

coderabbitai bot commented Nov 21, 2024

📝 Walkthrough

Walkthrough

The changes in this pull request involve significant modifications to the web application and backend services, primarily focusing on the removal of the RAG (Retrieval-Augmented Generation) functionality. This includes the deletion of multiple components, services, and modules related to RAG, such as RAG settings pages and associated components. Additionally, a new Dockerfile has been introduced for the web application, and updates have been made to the next.config.mjs file to enhance configuration management.

Changes

File Path Change Summary
apps/webapp/Dockerfile.slim Introduced a new Dockerfile with a multi-stage build process for a Node.js web application.
apps/webapp/next.config.mjs Added outputFileTracingRoot to the nextConfig object and imported necessary modules.
apps/webapp/src/app/(Dashboard)/configuration/page.tsx Removed RAGSettingsPage component and related tab structure from the dashboard configuration.
apps/webapp/src/components/Configuration/RAGSettings/* Deleted all files related to RAG settings: RAGItemDisplay.tsx, RAGItemList.tsx, RAGLayout.tsx, RAGSettingsPage.tsx, useRagItem.tsx, utils.ts.
packages/api/src/@core/@core-services/module.ts Removed RagModule and RagService from the module definition.
packages/api/src/@core/@core-services/unification/ingest-data.service.ts Removed ragService dependency and related logic from IngestDataService.
packages/api/src/@core/core.module.ts Removed RagModule from the CoreModule imports and exports.
packages/api/src/@core/rag/* Deleted all files related to RAG functionality, including services, controllers, and types.
packages/api/src/@core/s3/constants.ts Removed the BUCKET_NAME constant.
packages/api/src/@core/s3/s3.service.ts Deleted the S3Service class responsible for S3 interactions.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant WebApp
    participant API

    User->>WebApp: Request Dashboard
    WebApp->>API: Fetch Dashboard Data
    API-->>WebApp: Return Data
    WebApp-->>User: Render Dashboard without RAG Settings
Loading

Warning

There were issues while running some tools. Please review the errors and either fix the tool’s configuration or disable the tool if it’s a critical failure.

🔧 eslint (1.23.1)

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

apps/webapp/next.config.mjs

Oops! Something went wrong! :(

ESLint: 8.57.1

ESLint couldn't find the config "next/core-web-vitals" to extend from. Please check that the name of the config is correct.

The config "next/core-web-vitals" was referenced from the config file in "/apps/webapp/.eslintrc.json".

If you still have problems, please stop by https://eslint.org/chat/help to chat with the team.


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai or @coderabbitai title anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

zeropath-ai bot commented Nov 21, 2024

We have finished reviewing your PR. We have found no vulnerabilities.

Reply to this PR with @zeropath-ai followed by a description of what change you want and we'll auto-submit a change to this PR to implement it.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE

📥 Commits

Reviewing files that changed from the base of the PR and between 5d6a96c and 22d7418.

⛔ Files ignored due to path filters (1)
  • packages/api/swagger/swagger-spec.yaml is excluded by !**/*.yaml
📒 Files selected for processing (32)
  • apps/webapp/Dockerfile.slim (1 hunks)
  • apps/webapp/next.config.mjs (2 hunks)
  • apps/webapp/src/app/(Dashboard)/configuration/page.tsx (0 hunks)
  • apps/webapp/src/components/Configuration/RAGSettings/RAGItemDisplay.tsx (0 hunks)
  • apps/webapp/src/components/Configuration/RAGSettings/RAGItemList.tsx (0 hunks)
  • apps/webapp/src/components/Configuration/RAGSettings/RAGLayout.tsx (0 hunks)
  • apps/webapp/src/components/Configuration/RAGSettings/RAGSettingsPage.tsx (0 hunks)
  • apps/webapp/src/components/Configuration/RAGSettings/useRagItem.tsx (0 hunks)
  • apps/webapp/src/components/Configuration/RAGSettings/utils.ts (0 hunks)
  • packages/api/src/@core/@core-services/module.ts (1 hunks)
  • packages/api/src/@core/@core-services/unification/ingest-data.service.ts (0 hunks)
  • packages/api/src/@core/core.module.ts (0 hunks)
  • packages/api/src/@core/rag/chunking/chunking.service.ts (0 hunks)
  • packages/api/src/@core/rag/document.processor.ts (0 hunks)
  • packages/api/src/@core/rag/embedding/embedding.credentials.service.ts (0 hunks)
  • packages/api/src/@core/rag/embedding/embedding.service.ts (0 hunks)
  • packages/api/src/@core/rag/loader/loader.service.ts (0 hunks)
  • packages/api/src/@core/rag/rag.controller.ts (0 hunks)
  • packages/api/src/@core/rag/rag.dto.ts (0 hunks)
  • packages/api/src/@core/rag/rag.module.ts (0 hunks)
  • packages/api/src/@core/rag/rag.service.ts (0 hunks)
  • packages/api/src/@core/rag/types/index.ts (0 hunks)
  • packages/api/src/@core/rag/vecdb/chromadb/chromadb.service.ts (0 hunks)
  • packages/api/src/@core/rag/vecdb/milvus/milvus.service.ts (0 hunks)
  • packages/api/src/@core/rag/vecdb/pinecone/pinecone.service.ts (0 hunks)
  • packages/api/src/@core/rag/vecdb/qdrant/qdrant.service.ts (0 hunks)
  • packages/api/src/@core/rag/vecdb/turbopuffer/turbopuffer.service.ts (0 hunks)
  • packages/api/src/@core/rag/vecdb/vecdb.credentials.service.ts (0 hunks)
  • packages/api/src/@core/rag/vecdb/vecdb.service.ts (0 hunks)
  • packages/api/src/@core/rag/vecdb/weaviate/weaviate.service.ts (0 hunks)
  • packages/api/src/@core/s3/constants.ts (0 hunks)
  • packages/api/src/@core/s3/s3.service.ts (0 hunks)
💤 Files with no reviewable changes (29)
  • apps/webapp/src/app/(Dashboard)/configuration/page.tsx
  • apps/webapp/src/components/Configuration/RAGSettings/RAGItemDisplay.tsx
  • apps/webapp/src/components/Configuration/RAGSettings/RAGItemList.tsx
  • apps/webapp/src/components/Configuration/RAGSettings/RAGLayout.tsx
  • apps/webapp/src/components/Configuration/RAGSettings/RAGSettingsPage.tsx
  • apps/webapp/src/components/Configuration/RAGSettings/useRagItem.tsx
  • apps/webapp/src/components/Configuration/RAGSettings/utils.ts
  • packages/api/src/@core/@core-services/unification/ingest-data.service.ts
  • packages/api/src/@core/core.module.ts
  • packages/api/src/@core/rag/chunking/chunking.service.ts
  • packages/api/src/@core/rag/document.processor.ts
  • packages/api/src/@core/rag/embedding/embedding.credentials.service.ts
  • packages/api/src/@core/rag/embedding/embedding.service.ts
  • packages/api/src/@core/rag/loader/loader.service.ts
  • packages/api/src/@core/rag/rag.controller.ts
  • packages/api/src/@core/rag/rag.dto.ts
  • packages/api/src/@core/rag/rag.module.ts
  • packages/api/src/@core/rag/rag.service.ts
  • packages/api/src/@core/rag/types/index.ts
  • packages/api/src/@core/rag/vecdb/chromadb/chromadb.service.ts
  • packages/api/src/@core/rag/vecdb/milvus/milvus.service.ts
  • packages/api/src/@core/rag/vecdb/pinecone/pinecone.service.ts
  • packages/api/src/@core/rag/vecdb/qdrant/qdrant.service.ts
  • packages/api/src/@core/rag/vecdb/turbopuffer/turbopuffer.service.ts
  • packages/api/src/@core/rag/vecdb/vecdb.credentials.service.ts
  • packages/api/src/@core/rag/vecdb/vecdb.service.ts
  • packages/api/src/@core/rag/vecdb/weaviate/weaviate.service.ts
  • packages/api/src/@core/s3/constants.ts
  • packages/api/src/@core/s3/s3.service.ts
🧰 Additional context used
🪛 Hadolint (2.12.0)
apps/webapp/Dockerfile.slim

[warning] 4-4: Pin versions in apk add. Instead of apk add <package> use apk add <package>=<version>

(DL3018)


[warning] 31-31: Use WORKDIR to switch to a directory

(DL3003)


[info] 42-42: Multiple consecutive RUN instructions. Consider consolidation.

(DL3059)

🪛 Biome (1.9.4)
apps/webapp/next.config.mjs

[error] 2-2: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)


[error] 3-3: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)

🔇 Additional comments (4)
apps/webapp/next.config.mjs (2)

9-9: 🧹 Nitpick (assertive)

Verify Docker build configuration

The addition of outputFileTracingRoot is crucial for proper standalone builds, especially in Docker environments. This configuration ensures correct file tracing when building the Next.js application in a containerized environment.

Make sure to:

  1. Test the Docker build process to ensure all necessary files are included
  2. Verify that the path resolution works correctly in both development and production environments
  3. Consider documenting this configuration change in your deployment guides
✅ Verification successful

Docker build configuration is properly set up for standalone builds

The configuration is correctly implemented with proper Docker multi-stage builds and file tracing setup:

  • The Dockerfile uses appropriate multi-stage build process with proper workspace setup using Turbo
  • The outputFileTracingRoot setting in next.config.mjs is correctly pointing to the monorepo root
  • The .dockerignore properly excludes build artifacts while keeping necessary files for the build

Note: There's a commented warning about possible missing dependencies in standalone mode, but the outputFileTracingRoot configuration actually helps address this by ensuring correct file tracing from the monorepo root.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify Docker-related configurations
# Check for Dockerfile and docker-compose configurations that might need updates

# Look for Dockerfile
fd Dockerfile

# Check for docker-compose files
fd docker-compose

# Check for .dockerignore to ensure proper file inclusion/exclusion
if [ -f .dockerignore ]; then
    echo "Content of .dockerignore:"
    cat .dockerignore
fi

Length of output: 791


Script:

#!/bin/bash
# Check the content of webapp's Dockerfile to verify build configuration
cat apps/webapp/Dockerfile

# Check if there are any existing Next.js configurations in other files
rg -A 5 "outputFileTracingRoot" 

Length of output: 2207


Line range hint 1-21: Verify removal of RAG-related configurations

Since this PR aims to remove the RAG feature, let's verify that no RAG-related configurations remain in the codebase.

✅ Verification successful

No RAG-related configurations remain in Next.js config

The search results confirm that the Next.js configuration file and the entire codebase have been properly cleaned of RAG-specific configurations. While there are many file storage related configurations, these are part of the core functionality and not related to the RAG feature that was removed.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Search for any remaining RAG-related configurations

# Search for RAG-related terms in configuration files
echo "Checking for RAG-related configurations..."
rg -i "rag" --type=json --type=yaml --type=javascript --type=typescript

# Specifically check Next.js configuration files
echo "Checking Next.js config files..."
fd "next.config" --exec rg -i "rag" {}

Length of output: 315


Script:

#!/bin/bash
# Let's try a more comprehensive search with correct file extensions
echo "Searching for RAG-related configurations in JS/TS files..."
rg -i "rag" -g "*.js" -g "*.ts" -g "*.mjs" -g "*.json" -g "*.yaml" -g "*.yml"

echo -e "\nChecking Next.js config specifically..."
fd -e mjs -e js "next.config" -x cat {}

Length of output: 102515

🧰 Tools
🪛 Biome (1.9.4)

[error] 2-2: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)


[error] 3-3: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)

packages/api/src/@core/@core-services/module.ts (2)

17-17: Clean removal of RAG module confirmed

The removal of RagModule from imports aligns with the PR objective of removing the RAG feature. The remaining imports (BullQueueModule, RetryModule) maintain essential functionality.


Line range hint 17-43: Verify complete removal of RAG dependencies

Let's verify that there are no remaining references to RAG functionality in dependent modules to ensure a clean removal.

✅ Verification successful

RAG dependencies have been successfully removed

The search results confirm that there are no remaining RAG dependencies in the codebase that need attention. The occurrences of "rag" found in the search results are either:

  1. Part of unrelated words/terms:

    • "storage" in file storage related paths and descriptions
    • "drag" in UI component names and properties
    • "paragraph" in HTML element types
  2. Isolated to webapp hooks that are already being removed:

    • useRagSettings.tsx
    • useUpdateRagSettings.tsx

The codebase appears clean with no remaining RAG functionality dependencies that require attention.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Search for any remaining RAG-related references in the codebase

# Search for RAG-related imports, services, or configuration
echo "Searching for RAG-related code..."
rg -i "rag" --type ts --type tsx \
    --glob '!{*.test.*,*.spec.*}' \
    -g '!**/dist/**' \
    -g '!**/node_modules/**'

# Search for potential TODO comments about RAG
echo "Searching for RAG-related TODO comments..."
rg -i "todo.*rag" --type ts --type tsx \
    --glob '!{*.test.*,*.spec.*}' \
    -g '!**/dist/**' \
    -g '!**/node_modules/**'

Length of output: 445


Script:

#!/bin/bash
# Let's modify the search to use only --type ts and add more context with -C flag
echo "Searching for RAG-related code..."
rg -i "rag" --type ts -C 2 \
    --glob '!{*.test.*,*.spec.*}' \
    -g '!**/dist/**' \
    -g '!**/node_modules/**'

# Let's also search for specific RAG-related class or service names
echo "Searching for specific RAG patterns..."
rg -i "(ragservice|ragmodule|ragconfig|ragrepository)" --type ts -C 2 \
    --glob '!{*.test.*,*.spec.*}' \
    -g '!**/dist/**' \
    -g '!**/node_modules/**'

# Let's check for any RAG-related imports
echo "Searching for RAG imports..."
ast-grep --pattern 'import { $$$RAG$$$ } from "$_"'

Length of output: 113036


Script:

#!/bin/bash
# Let's search for RAG-related code in the webapp and hooks specifically
echo "Searching for RAG-related code in webapp..."
rg -i "rag" --type ts -C 2 \
    -g "apps/webapp/**" \
    --glob '!{*.test.*,*.spec.*}' \
    -g '!**/dist/**' \
    -g '!**/node_modules/**'

# Let's also check for any RAG-related components or services
echo "Searching for RAG-related components and services..."
rg -i "(userag|ragcomponent|ragservice)" --type ts -C 2 \
    -g "apps/webapp/**" \
    --glob '!{*.test.*,*.spec.*}' \
    -g '!**/dist/**' \
    -g '!**/node_modules/**'

# Let's check for any RAG-related API endpoints
echo "Searching for RAG-related API endpoints..."
rg -i "rag" --type ts -C 2 \
    -g "packages/api/src/**/*.controller.ts" \
    --glob '!{*.test.*,*.spec.*}' \
    -g '!**/dist/**' \
    -g '!**/node_modules/**'

Length of output: 29916

Comment on lines +2 to +3
import path from 'path';
import { fileURLToPath } from 'url';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Use the node: protocol for Node.js built-in modules

For better clarity and explicit identification of Node.js built-in modules, use the node: protocol prefix.

-import path from 'path';
-import { fileURLToPath } from 'url';
+import path from 'node:path';
+import { fileURLToPath } from 'node:url';
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
import path from 'path';
import { fileURLToPath } from 'url';
import path from 'node:path';
import { fileURLToPath } from 'node:url';
🧰 Tools
🪛 Biome (1.9.4)

[error] 2-2: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)


[error] 3-3: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)

Comment on lines +52 to +53
# Install only production dependencies

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Remove or update the comment about installing production dependencies

The comment # Install only production dependencies is not followed by any commands, which might cause confusion.

If no action is needed here, consider removing the comment:

- # Install only production dependencies

Alternatively, if you need to install production dependencies, add the appropriate command after the comment.

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
# Install only production dependencies

Comment on lines +41 to +42
RUN addgroup --system --gid 1001 nodejs
RUN adduser --system --uid 1001 nextjs
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Consolidate consecutive RUN instructions to optimize image layers

Combining multiple RUN commands into one reduces the number of layers in the final image, improving build efficiency.

You can modify the commands as follows:

- RUN addgroup --system --gid 1001 nodejs
- RUN adduser --system --uid 1001 nextjs
+ RUN addgroup --system --gid 1001 nodejs && \
+     adduser --system --uid 1001 nextjs
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
RUN addgroup --system --gid 1001 nodejs
RUN adduser --system --uid 1001 nextjs
RUN addgroup --system --gid 1001 nodejs && \
adduser --system --uid 1001 nextjs
🧰 Tools
🪛 Hadolint (2.12.0)

[info] 42-42: Multiple consecutive RUN instructions. Consider consolidation.

(DL3059)

Comment on lines +4 to +5
RUN apk add --no-cache libc6-compat && \
corepack enable
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Pin versions in apk add command for reproducible builds

To ensure reproducible builds and prevent unexpected issues from package updates, it's recommended to pin the versions when installing packages with apk add.

You can modify the command as follows:

- RUN apk add --no-cache libc6-compat && \
+ RUN apk add --no-cache libc6-compat=<version> && \

Replace <version> with the specific version number required.

Committable suggestion skipped: line range outside the PR's diff.

🧰 Tools
🪛 Hadolint (2.12.0)

[warning] 4-4: Pin versions in apk add. Instead of apk add <package> use apk add <package>=<version>

(DL3018)

RUN pnpm install --shamefully-hoist

# Build shared package first
RUN cd packages/shared && pnpm run build
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Use WORKDIR instead of cd for changing directories

Using WORKDIR to change directories is more efficient and makes the Dockerfile cleaner compared to using cd in a RUN command.

You can modify the Dockerfile like this:

- RUN cd packages/shared && pnpm run build
+ WORKDIR /app/packages/shared
+ RUN pnpm run build

If you need to return to the previous directory, you can add another WORKDIR command after the build step.

Committable suggestion skipped: line range outside the PR's diff.

🧰 Tools
🪛 Hadolint (2.12.0)

[warning] 31-31: Use WORKDIR to switch to a directory

(DL3003)

@rflihxyz rflihxyz merged commit b22f563 into main Nov 21, 2024
16 of 17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant